package com.example.manu_facturer_orders.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.example.manu_facturer_orders.pojo.EnginnerVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author: tobed
 * @date: 2022/9/12
 * @time: 11:04
 */
@Mapper
public interface EngineerMapper {

    /**
     * 工程师查询
     * @param userCode
     * @param userName
     * @param page
     * @return
     */
    Page<EnginnerVO> listEnginner(
            @Param("userCode") String userCode,
            @Param("userName")  String userName,
            @Param("contractStatus") Integer contractStatus,
            Page<EnginnerVO> page);


    /**
     * 解约工程师
     * @param id
     * @return
     */
    int terminationEngineer(@Param("id") Integer id);

    /**
     * 无分页全查未签约
     * @return
     */
    List<EnginnerVO> listEngineerNoPage();

    int contractEngineer(@Param("id") List<String> id);

    /**
     * 启用&停用工程师
     * @param id
     * @param s
     * @return
     */
    int stopOrOpenEngineer(@Param("id") Integer id,@Param("status") Integer status);

}
